
/*
 *
 *  Copyright (C) 2012-2024
 *  All rights reserved, Designed By 杭州连线客信息技术有限公司
 *  注意：
 *  本软件为杭州连线客信息技术有限公司开发研制，未经购买不得使用
 *  购买后可获得全部源代码（禁止转卖、分享、上传到码云、github等开源平台）
 *  一经发现盗用、分享等行为，将追究法律责任，后果自负
 *
 */

package com.lxk.oms.postorder.domain.bo;

import com.lxk.oms.postorder.domain.OmsPostOrderItem;
import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import org.dromara.common.mybatis.core.domain.BaseEntity;

import java.math.BigDecimal;

/**
 * 订单售后明细业务对象 oms_post_order_item
 *
 * @author LXK-RY5
 * @date 2024-09-28
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = OmsPostOrderItem.class, reverseConvertGenerate = false)
public class OmsPostOrderItemBo extends BaseEntity {

    /**
     * ID
     */
    @NotNull(message = "ID不能为空", groups = { EditGroup.class })
    private Long id;

    /**
     * 商户id
     */
    @NotNull(message = "商户id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long merId;

    /**
     * 售后订单ID
     */
    @NotNull(message = "售后订单ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long postOrderId;

    /**
     * 订单主键id
     */
    @NotNull(message = "订单主键id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long orderId;

    /**
     * 商品 SPU ID
     */
    @NotNull(message = "商品 SPU ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long spuId;

    /**
     * 商品 SPU 名称
     */
//    @NotBlank(message = "商品 SPU 名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String spuName;

    /**
     * spu主图
     */
    private String spuImage;

    /**
     * sku图片
     */
    @NotBlank(message = "sku图片不能为空", groups = { AddGroup.class, EditGroup.class })
    private String skuImage;

    /**
     * 商品 SKU ID
     */
    @NotNull(message = "商品 SKU ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long skuId;

    /**
     * SKU名称
     */
    @NotBlank(message = "SKU名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String skuName;

    /**
     * 用户ID
     */
    @NotNull(message = "用户ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long userId;

    /**
     * 退款金额
     */
    @NotNull(message = "退款金额不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal refundAmount;

    /**
     * 售后数量
     */
    @NotNull(message = "售后数量不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer refundCount;

    /**
     * 实际退款金额
     */
    @NotNull(message = "实际退款金额不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal actRefundAmount;


    /**
     * 子订单ID
     */
    private Long orderItemId;

}
